package cn.zwx.common.swagger.starter.controller;

import cn.zwx.base.entity.ResponseEntity;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

import javax.validation.Valid;

@RestController
@Api(tags = "用户信息注册")
@RequestMapping("/swagger")
public class SwaggerController {


    @ApiOperation(value = "查询用户信息")
    @RequestMapping(value = "/queryUserInfo",method = RequestMethod.POST)
    public ResponseEntity<UserInfoVO> queryUserInfo(@Valid @RequestBody UserInfoDTO dt0){
        return ResponseEntity.success(new UserInfoVO(dt0.getUserId(),"张学友"));
    }
}
